package com.example.home.model

import com.example.home.api.VideoApiService
import com.example.home.entity.SimpleTypeEntity
import com.example.home.entity.VideoListEntity
import com.example.net.RetrofitFactory
import com.example.net.BaseResponse
import retrofit2.http.Query

open class VideoModel {
    //拼接
    private val api: VideoApiService =RetrofitFactory.getRetrofitFactory().create(VideoApiService::class.java)

    suspend fun getVideo(): BaseResponse<List<SimpleTypeEntity>> {
        return api.getVideoType()
    }
    suspend fun getVideoList(id:String,page:Int,size:Int):BaseResponse<List<VideoListEntity>>{
        return api.getVideoList(id,page, size)
    }
}